package kr.co.doriclassic.mypuppystory;

import kr.co.doriclassic.mypuppystory.CarouselAdapter.OnItemClickListener;
import kr.co.doriclassic.mypuppystory.alarmpuppy.AlarmPuppy;
import kr.co.doriclassic.mypuppystory.infopuppy.Json_parserAcitivity;
import kr.co.doriclassic.mypuppystory.kind.KindPuppy;
import kr.co.doriclassic.mypuppystory.memo.MultiMemoActivity;
import kr.co.doriclassic.mypuppystory.searchpuppy.SearchPuppy;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;

public class MainActivity extends Activity {
	private Intent intent;

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.main);

		Carousel carousel = (Carousel) findViewById(R.id.carousel);
		carousel.setOnItemClickListener(new OnItemClickListener() {

			@Override
			public void onItemClick(CarouselAdapter<?> parent, View view,
					int position, long id) {
				switch (position) {
				case 0:
					//Log.d("chick", position+"");
					intent = new Intent(getApplicationContext(), KindPuppy.class);
					break;
				case 1:
					//Log.d("chick", position+"");
					intent = new Intent(getApplicationContext(), SearchPuppy.class);
					break;
				case 2:
					//Log.d("chick", position+"");
					intent = new Intent(getApplicationContext(), Json_parserAcitivity.class);
					break;
				case 3:
					//Log.d("chick", position+"");
					intent = new Intent(getApplicationContext(), AlarmPuppy.class);
					break;
				case 4:
					//Log.d("chick", position+"");
					intent = new Intent(getApplicationContext(), MultiMemoActivity.class);
					break;
				}
				startActivity(intent);
			}
		});
	}
}